package com.example.dakotanews.dto;

import com.example.dakotanews.entity.comment.NewsChildComment;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

@Data
@AllArgsConstructor
@NoArgsConstructor
public class ChildCommentDTO {

    private Integer id;
    private String nickname;
    private Integer userId;
    private String profile;
    private String repliedNickname;
    private String comment;
    private String commitTime;
    private int supportNum;
    private int supportIf;

    public ChildCommentDTO(NewsChildComment newsChildComment) {
        this.id = newsChildComment.getId();
        this.userId = newsChildComment.getUserId();
        this.comment = newsChildComment.getComment();
        this.supportNum = newsChildComment.getSupportNum();
    }
}
